import React from "react";

import useCounter from "./utils/useCounter";
import useTime from "./utils/useTime";

const App = () => {
  const [count, add, minus] = useCounter();
  const timeStr = useTime();

  return (
    <>
      <h2>useDebugValue</h2>
      {/* 计数器的功能 */}
      <button onClick={minus}>-</button>
      <span>{count}</span>
      <button onClick={add}>+</button>

      {/* 显示当前时间的功能 */}
      <p>{timeStr}</p>
    </>
  );
};

export default App;
